﻿/*
 * 2010-5-19 16:38:10.
 *
 *  liuxing@91huayi.com
 */
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace JKF.Substructure.Form
{
    public class TextBox : System.Web.UI.WebControls.TextBox, IValueable
    {
        public string Value
        {
            get
            {
                return base.Text.ToSqlString(this.MaxLength);
            }
            set
            {
                base.Text = value;
            }
        }

        private bool _setMaxLength = false;
        private int _maxLength = 20;

        public override int MaxLength
        {
            get
            {
                return _maxLength;
            }
            set
            {
                _maxLength = value;
                _setMaxLength = true;
            }
        }
    }
}
